package com.liao.badminton.vo;

import com.liao.badminton.code.BaseField;
import io.swagger.annotations.ApiModelProperty;

import java.lang.String;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

import lombok.Data;
import com.liao.badminton.entity.ActivityRecord;

/**
 * @author liaocheng
 * @date 2024-11-15
 * description:群发布活动记录表
 */
@Data
public class ActivityRecordVo extends BaseField {

    @ApiModelProperty(value = "id")
    private Long id;

    @ApiModelProperty(value = "群id")
    private Long groupId;

    @ApiModelProperty(value = "活动文本内容")
    private String txtContent;

    @ApiModelProperty(value = "参与人数:20")
    private Integer joinNum;

    @ApiModelProperty(value = "免费人数:10")
    private Integer FeeNum;
    @ApiModelProperty(value = "全程男生人数:10")
    private Integer fullMaleNum;

    @ApiModelProperty(value = "全程女生人数:10")
    private Integer fullFemaleNum;

    @ApiModelProperty(value = "半程男生人数:10")
    private Integer halfMaleNum;

    @ApiModelProperty(value = "半程女生人数:10")
    private Integer halfFemaleNum;
    private Integer fullAbsentNum;  //飞机人数:10
    private Integer halfAbsentNum;  //半飞机人数:10
    @ApiModelProperty(value = "是否结算：0未结算，1已结算")
    private Integer settlementFlag;

    @ApiModelProperty(value = "总花费")
    private BigDecimal totalCost;
    private Integer collectType;  //收费方式：0均摊，1固定
    private BigDecimal fixedMale;  //男生固定价格
    private BigDecimal fixedFemale;  //女生固定价格
    private BigDecimal extraPerCost;  //额外每人：2玩
    private BigDecimal extraFixedCost;  //额外固定：组一场球收50
    @ApiModelProperty(value = "女生优惠价格5:不填就用群设置的")
    private BigDecimal femaleDiscountPrice;

    @ApiModelProperty(value = "场地数:2")
    private Integer siteNum;

    @ApiModelProperty(value = "场地价格/块/小时:80")
    private BigDecimal sitePerPrice;

    @ApiModelProperty(value = "场地总价:320")
    private BigDecimal siteTotalCost;

    @ApiModelProperty(value = "球总花费：0")
    private BigDecimal ballTotalCost;

    @ApiModelProperty(value = "时长:2.5")
    private BigDecimal timeLength;

    @ApiModelProperty(value = "使用球数:10")
    private Integer costBallNum;

    @ApiModelProperty(value = "每桶球数:12，不填就用群设置的")
    private Integer bucketBallNum;

    @ApiModelProperty(value = "每桶球价值:120，不填就用群设置的")
    private BigDecimal bucketPerPrice;

    @ApiModelProperty(value = "是否有效：0:无效，1:有效(导入统计)")
    private Integer validStatus;

    private List<Long> delIds;  //批量删除ids


    @ApiModelProperty(value = "参与人列表")
    List<ActivityParticipatorVo> activityParticipatorVos;  //参与人列表

    public static ActivityRecordVo invertToVo(ActivityRecord activityRecord) {
        ActivityRecordVo vo = new ActivityRecordVo();
        BaseField.invert(activityRecord, vo);
        vo.setId(activityRecord.getId());
        vo.setGroupId(activityRecord.getGroupId());
        vo.setTxtContent(activityRecord.getTxtContent());
        vo.setJoinNum(activityRecord.getJoinNum());
        vo.setFeeNum(activityRecord.getFeeNum());
        vo.setFullMaleNum(activityRecord.getFullMaleNum());
        vo.setFullFemaleNum(activityRecord.getFullFemaleNum());
        vo.setHalfMaleNum(activityRecord.getHalfMaleNum());
        vo.setHalfFemaleNum(activityRecord.getHalfFemaleNum());
        vo.setFullAbsentNum(activityRecord.getFullAbsentNum());
        vo.setHalfAbsentNum(activityRecord.getHalfAbsentNum());
        vo.setSettlementFlag(activityRecord.getSettlementFlag());
        vo.setTotalCost(activityRecord.getTotalCost());
        vo.setCollectType(activityRecord.getCollectType());
        vo.setFixedMale(activityRecord.getFixedMale());
        vo.setFixedFemale(activityRecord.getFixedFemale());
        vo.setExtraPerCost(activityRecord.getExtraPerCost());
        vo.setExtraFixedCost(activityRecord.getExtraFixedCost());
        vo.setFemaleDiscountPrice(activityRecord.getFemaleDiscountPrice());
        vo.setSiteNum(activityRecord.getSiteNum());
        vo.setSitePerPrice(activityRecord.getSitePerPrice());
        vo.setSiteTotalCost(activityRecord.getSiteTotalCost());
        vo.setBallTotalCost(activityRecord.getBallTotalCost());
        vo.setTimeLength(activityRecord.getTimeLength());
        vo.setCostBallNum(activityRecord.getCostBallNum());
        vo.setBucketBallNum(activityRecord.getBucketBallNum());
        vo.setBucketPerPrice(activityRecord.getBucketPerPrice());
        vo.setValidStatus(activityRecord.getValidStatus());
        return vo;
    }
}
